/**
 * Generate time : 2011-06-27 5:55:00
 * Version : 1.0.1.V20070717
 */
package com.baosight.sczx.zm.cc.domain;

import com.baosight.iplat4j.util.NumberUtils;
import com.baosight.iplat4j.core.ei.EiColumn;
import com.baosight.iplat4j.ep.DaoEPBase;
import java.util.HashMap;
import java.util.Map;
import com.baosight.iplat4j.util.StringUtils;

/**
 * ZMCC5examineClassify
 * 
 */
public class ZMCC5examineClassify extends DaoEPBase {

	private String fdKeyId = " "; /* 主键 */
	private String fdClassifyName = " "; /* 分项名称 */
	private Long fdSerialnum = new Long(0); /* 顺序号 */
	private String fdStatus = " "; /* 状态 */

	/**
	 * initialize the metadata
	 */
	public void initMetaData() {
		EiColumn eiColumn;

		eiColumn = new EiColumn("fdKeyId");
		eiColumn.setPrimaryKey(true);
		eiColumn.setFieldLength(32);
		eiColumn.setDescName("主键");
		eiMetadata.addMeta(eiColumn);

		eiColumn = new EiColumn("fdClassifyName");
		eiColumn.setFieldLength(50);
		eiColumn.setDescName("分项名称");
		eiMetadata.addMeta(eiColumn);

		eiColumn = new EiColumn("fdSerialnum");
		eiColumn.setType("N");
		eiColumn.setScaleLength(0);
		eiColumn.setFieldLength(38);
		eiColumn.setDescName("顺序号");
		eiMetadata.addMeta(eiColumn);

		eiColumn = new EiColumn("fdStatus");
		eiColumn.setFieldLength(10);
		eiColumn.setDescName("状态");
		eiMetadata.addMeta(eiColumn);

	}

	/**
	 * the constructor
	 */
	public ZMCC5examineClassify() {
		initMetaData();
	}

	/**
	 * get the fdKeyId - 主键
	 * 
	 * @return the fdKeyId
	 */
	public String getFdKeyId() {
		return this.fdKeyId;
	}

	/**
	 * set the fdKeyId - 主键
	 */
	public void setFdKeyId(String fdKeyId) {
		this.fdKeyId = fdKeyId;
	}

	/**
	 * get the fdClassifyName - 分项名称
	 * 
	 * @return the fdClassifyName
	 */
	public String getFdClassifyName() {
		return this.fdClassifyName;
	}

	/**
	 * set the fdClassifyName - 分项名称
	 */
	public void setFdClassifyName(String fdClassifyName) {
		this.fdClassifyName = fdClassifyName;
	}

	/**
	 * get the fdSerialnum - 顺序号
	 * 
	 * @return the fdSerialnum
	 */
	public Long getFdSerialnum() {
		return this.fdSerialnum;
	}

	/**
	 * set the fdSerialnum - 顺序号
	 */
	public void setFdSerialnum(Long fdSerialnum) {
		this.fdSerialnum = fdSerialnum;
	}

	/**
	 * get the fdStatus - 状态
	 * 
	 * @return the fdStatus
	 */
	public String getFdStatus() {
		return this.fdStatus;
	}

	/**
	 * set the fdStatus - 状态
	 */
	public void setFdStatus(String fdStatus) {
		this.fdStatus = fdStatus;
	}

	/**
	 * get the value from Map
	 */
	@SuppressWarnings("rawtypes")
	public void fromMap(Map map) {

		setFdKeyId(StringUtils.defaultIfEmpty(StringUtils.toString(map.get("fdKeyId")), fdKeyId));
		setFdClassifyName(StringUtils.defaultIfEmpty(StringUtils.toString(map.get("fdClassifyName")), fdClassifyName));
		setFdSerialnum(NumberUtils.toLong(StringUtils.toString(map.get("fdSerialnum")), fdSerialnum));
		setFdStatus(StringUtils.defaultIfEmpty(StringUtils.toString(map.get("fdStatus")), fdStatus));
	}

	/**
	 * set the value to Map
	 */
	@SuppressWarnings({ "rawtypes", "unchecked" })
	public Map toMap() {

		Map map = new HashMap();
		map.put("fdKeyId", StringUtils.toString(fdKeyId, eiMetadata.getMeta("fdKeyId")));
		map.put("fdClassifyName", StringUtils.toString(fdClassifyName, eiMetadata.getMeta("fdClassifyName")));
		map.put("fdSerialnum", StringUtils.toString(fdSerialnum, eiMetadata.getMeta("fdSerialnum")));
		map.put("fdStatus", StringUtils.toString(fdStatus, eiMetadata.getMeta("fdStatus")));

		return map;

	}
}